<%--
  Created by IntelliJ IDEA.
  User: 橙子柚子。
  Date: 2018/4/1
  Time: 10:25
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>application测试</title>
</head>
<body>
  <!--jsp 声明-->
  <%!
    int i;
  %>
  <!--将i的值自加后放入application的变量内-->
  <%
     application.setAttribute("counter",String.valueOf(++i));
  %>
  <!--输出i的值-->
  <%=i%>
</body>
</html>
